package com.tyk.bookstore.back.platform.model.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;

/**
 * @author tyk
 * @description 行政区域
 */
@Schema(name = "AreaDo", description = "行政区域")
@Data
@TableName("area")
public class AreaDo  implements Serializable{

    @Serial
    private static final long serialVersionUID = 1L;

    @Schema(description = "行政区划代码")
    @TableId(value = "code")
    private Long code;

    @Schema(description = "父级行政区划代码")
    @TableField("parent_code")
    private Long parentCode;

    @Schema(description = "名称")
    @TableField("name")
    private String name;
}
